﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml;
using System.Xml.Serialization;
using System.IO;

namespace VelesServiceLibrary
{
    public class ServiceOption
    {
        static string bzz;

        public static string Bzz
        {
            get { return ServiceOption.bzz; }
            set { ServiceOption.bzz = value; }
        }



        public const string FileName = "ServiceOption.xml";

        const string DefaultServiceURI = "http://localhost:8080/";
        const string DefaultServer = @"R2D2\SQL2008R2";
        const string DefaultDbName = "Veles";
        const string DefaultSaPassword = "1";

        string serviceURI;

        public string ServiceURI
        {
            get { return (serviceURI != null) ? serviceURI : DefaultServiceURI; }
            set { serviceURI = value; }
        }

        string server;

        public string Server
        {
            get { return (server != null) ? server : DefaultServer; }
            set { server = value; }
        }

        string dbName;

        public string DbName
        {
            get { return (dbName != null) ? dbName : DefaultDbName; }
            set { dbName = value; }
        }

        string saPassword;

        public string SaPassword
        {
            get { return (saPassword != null) ? saPassword : DefaultSaPassword; }
            set { saPassword = value; }
        }
    }
}
